<!DOCTYPE html>
<html xmlns:th="http://thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
    <!-- Bootstrap 3.3.7 -->
    <link rel="stylesheet"th:href="@{/adminlte/bower_components/bootstrap/dist/css/bootstrap.min.css}">
    <!-- Font Awesome -->
    <link rel="stylesheet"th:href="@{/adminlte/bower_components/font-awesome/css/font-awesome.min.css}">
    <!-- Ionicons -->
    <link rel="stylesheet"th:href="@{/adminlte/bower_components/Ionicons/css/ionicons.min.css}">
    <!-- DataTables -->
    <link rel="stylesheet"th:href="@{/adminlte/bower_components/datatables.net-bs/css/dataTables.bootstrap.min.css}">
    <!-- Theme style -->
    <link rel="stylesheet"th:href="@{/adminlte/dist/css/AdminLTE.min.css}">
    <!-- AdminLTE Skins. Choose a skin from the css/skins
         folder instead of downloading all of them to reduce the load. -->
    <link rel="stylesheet"th:href="@{/adminlte/dist/css/skins/_all-skins.min.css}">
    <link rel="stylesheet" th:href="@{/bootstrap-table/bootstrap-table.min.css}">
    <script th:src="@{/bootstrap-table/bootstrap-table.min.js}"></script>
    <script th:src="@{/bootstrap-table/locale/bootstrap-table-zh-CN.js}"></script>
    <script th:src="@{/js/jquery-3.4.1.min.js}"></script>
    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
    <script th:src="@{https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js}"></script>
    <script th:src="@{https://oss.maxcdn.com/respond/1.4.2/respond.min.js}"></script>
    <![endif]-->

    <!-- Google Font -->
    <link rel="stylesheet"
          href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,600,700,300italic,400italic,600italic">
</head>
<body>
<div class="container" style="margin-right: 1000px">
    <table class="table table-bordered table-hover  table-condensed">
        <caption>分类列表</caption>
        <thead>
        <tr class="success">
            <th>ID</th>
            <th>商品名称</th>
            <th>商品价格</th>
            <th>商品简介</th>
            <th>商品图片</th>
            <th>商品数量</th>
            <th>是否打折</th>
        </tr>
        </thead>
        <tbody>
        <tr th:each="p : ${ps}">
            <td th:text="${p.pId}"></td>
            <td th:text="${p.productName}"></td>
            <td th:text="${p.money}"></td>
            <td th:text="${p.content}"></td>
            <td><img height="80px" th:src="@{'/DictionaryImage/'+${p.productPic}+.jpg}"></td>
            <td th:text="${p.num}"></td>
            <td th:text="${p.dazhe}"></td>
            <td></td>
<!--            <td><img height="50px" th:src="@{'/DictionaryImage/'+${d.dId}+.jpg}"/></td>-->
<!--            <td><a th:href="'/Dictionary/dictionary_edit?dId=' +${d.dId}"><span class="glyphicon glyphicon-edit"></span></a></td>-->
<!--            <td><a th:href="'/Dictionary/dictionary_delete?dId=' +${d.dId}" class="btn btn-danger btn-xs btn_del">删除</a></td>-->

        </tr>

        </tbody>
    </table>


</div>
<script th:src="@{/adminlte/bower_components/jquery/dist/jquery.min.js}"></script>
<!-- Bootstrap 3.3.7 -->
<script th:src="@{/adminlte/bower_components/bootstrap/dist/js/bootstrap.min.js}"></script>
<!-- DataTables -->
<script th:src="@{/adminlte/bower_components/datatables.net/js/jquery.dataTables.min.js}"></script>
<script th:src="@{/adminlte/bower_components/datatables.net-bs/js/dataTables.bootstrap.min.js}"></script>
<!-- SlimScroll -->
<script th:src="@{/adminlte/bower_components/jquery-slimscroll/jquery.slimscroll.min.js}"></script>
<!-- FastClick -->
<script th:src="@{/adminlte/bower_components/fastclick/lib/fastclick.js}"></script>
<!-- AdminLTE App -->
<script th:src="@{/adminlte/dist/js/adminlte.min.js}"></script>
<!-- AdminLTE for demo purposes -->
<script th:src="@{/adminlte/dist/js/demo.js}"></script>
</body>
<script>
    $(function () {
        $("#update").click($(function (){
            var $tr = $(this).parents("tr");
            var dId = $tr.attr("dId");
            layer.open({
                title: '更新信息',
                type: 2,
                area: ['300px', '700px'],
                content: "${pageContext.request.contextPath}/Dictionary/dictionary_update?id=" + dId
            })
        }))
    })
</script>
</html>